{if !$bUseAjax}
	<form method="post" action="{url link='current'}" style="margin:0px;">
		<select name="rating" {literal}onchange="if (this.value!='false') { submit(); }"{/literal}>
		<option value="false">Select</option>
		<option value="10">10</option>
		<option value="9">9</option>
		<option value="8">8</option>
		<option value="7">7</option>
		<option value="6">6</option>
		<option value="5">5</option>
		<option value="4">4</option>
		<option value="3">3</option>
		<option value="2">2</option>
		<option value="1">1</option>
		</select>
	</form>
{else}
<script type="text/javascript" src="design/js/stars.js"></script>
<script type="text/javascript">
{literal}
function start_rating()
{
	document.getElementById('ratingMessage').style.display='none';
	document.getElementById('show_stars').style.display='none';
	document.getElementById('ajax_rating_loader').style.display='';
}
{/literal}
</script>

<table style="font-size:10pt;" class="color" cellpadding="0" cellspacing="0">
<tr>
	<td style="vertical-align:top;">
	<div id="ratingDiv">

	<form style="display:none;" name="ratingForm" action="#" method="post"></form>

	<div id="show_stars">
	<a href="#" onclick="start_rating(); xajax_setStars('2', '{$iId}'); return false;" onmouseover="ratingComponent.showStars(1);" onmouseout="ratingComponent.clearStars();">
	<img src="design/pic/stars/icn_star_empty_19x20.png" id="star__1" class="rating" style="border: 0px; vertical-align:bottom;" /></a>

	<a href="#" onclick="start_rating(); xajax_setStars('4', '{$iId}'); return false;" onmouseover="ratingComponent.showStars(2);" onmouseout="ratingComponent.clearStars();">
	<img src="design/pic/stars/icn_star_empty_19x20.png" id="star__2" class="rating" style="border: 0px; vertical-align:bottom;" /></a>

	<a href="#" onclick="start_rating(); xajax_setStars('6', '{$iId}'); return false;" onmouseover="ratingComponent.showStars(3);" onmouseout="ratingComponent.clearStars();">
	<img src="design/pic/stars/icn_star_empty_19x20.png" id="star__3" class="rating" style="border: 0px; vertical-align:bottom;" /></a>

	<a href="#" onclick="start_rating(); xajax_setStars('8', '{$iId}'); return false;" onmouseover="ratingComponent.showStars(4);" onmouseout="ratingComponent.clearStars();">
	<img src="design/pic/stars/icn_star_empty_19x20.png" id="star__4" class="rating" style="border: 0px; vertical-align:bottom;" /></a>

	<a href="#" onclick="start_rating(); xajax_setStars('10', '{$iId}'); return false;" onmouseover="ratingComponent.showStars(5);" onmouseout="ratingComponent.clearStars();">
	<img src="design/pic/stars/icn_star_empty_19x20.png" id="star__5" class="rating" style="border: 0px; vertical-align:bottom;" /></a>

	<div style="padding:2px;">
	{$iTotal} {language text='Mod_Video.ratings'}
	</div>

	</div>

	</div>
	</td>
	<td style="font-weight:bold;vertical-align:top;">
	<div style="padding-left:4px;">
		<span id="ajax_rating_loader" style="display:none;font-size:10pt;font-weight:bold;">
			<img src="design/pic/loader.gif" alt="" style="vertical-align:bottom;" /> {language text='Mod_Video.rate.this.video'}
		</span>
		<div id="ratingMessage"></div>
		<div id="thanksMessage"></div>
	</div>
	</td>
</tr>
</table>
{/if}

<script type="text/javascript">
	messages = new Array("{language text='Mod_Video.rate.rateit'}", "{language text='Mod_Video.rate.poor'}", "{language text='Mod_Video.rate.nothing.special'}", "{language text='Mod_Video.worth.watching'}", "{language text='Mod_Video.pretty.cool'}", "{language text='Mod_Video.awesome'}");
	ratingComponent = new UTRating('ratingDiv', 5, 'ratingComponent', 'ratingForm', 'ratingMessage', '', 'L', messages);
	ratingComponent.starCount={$showStars};
	ratingComponent.clearStars();
</script>